package com.quanyan.place.mapper;

import com.quanyan.place.entity.TbBizPlacePayItem;
import com.quanyan.place.entity.apireq.ReqPlaceRevenueStreamVo;
import com.quanyan.place.entity.vo.PlaceRevenueStreamVo;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;
import java.util.Objects;

/**
 * Created by Administrator on 2016/7/30.
 */
public interface FinanceCommonManagerMapper {
    /**
     * 后台订单预订实付的金额
     * @param map
     * @return
     */
    BigDecimal getDiscountAmountByBook(@Param("map") Map<String, Object> map);

    /**
     * 后台订单实付的金额
     * @param map
     * @return
     */
    BigDecimal getDiscountAmount(@Param("map") Map<String, Object> map);

    /**
     * 客户端订单实付金额
     * @param map
     * @return
     */
    BigDecimal getOrderDiscountAmount(@Param("map") Map<String, Object> map);

    /**
     * 订单流水列表
     * @param reqPlaceRevenueStreamVo
     * @return
     */
    List<PlaceRevenueStreamVo> selectPlaceRevenueStream(@Param("reqPlaceRevenueStreamVo") ReqPlaceRevenueStreamVo reqPlaceRevenueStreamVo);

    /**
     * 订单流水记录数
     * @param reqPlaceRevenueStreamVo
     * @return
     */
    Integer selectPlaceRevenueStreamCount(@Param("reqPlaceRevenueStreamVo") ReqPlaceRevenueStreamVo reqPlaceRevenueStreamVo);

    /***
     * 根据payId分组统计金额
     * @param map
     * @return
     */
    List<TbBizPlacePayItem> getPayItemGroupByType(@Param("map") Map<String,Object> map);
}
